<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>

  <div ng-app="" ng-init="firstName='John';">
    <p>在输入框中尝试输入：</p>
    <p>姓名：<input type="text" ng-model="firstName"></p>
    <p>你输入的为： {{ firstName }}</p>

    <hr>
    <h2 ng-init="quantity=1;price=5">价格计算器</h2>
    数量： <input type="number" ng-model="quantity">
    价格： <input type="number" ng-model="price">
    <p><b>总价：</b> {{ quantity * price }}</p>

    <hr>
    <h2>使用 ng-repeat 来循环数组</h2>
    <div ng-init="names=['Jani','Hege','Kai']">
      <ul>
        <li ng-repeat="x in names">
          {{ x }}
        </li>
      </ul>
    </div>
  </div>


  <script src="./static/angular.min.js"></script>

</body>

</html>